﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Academy.Numerics;

namespace Academy.Collections.Generic
{
    /// <summary>
    /// Defines a set of methods that a type implements to provide arithmetic operations results 
    /// using two <see cref="T:Academy.Collections.Generic.IMatrix`1"/> implementations.
    /// </summary>
    /// <typeparam name="T">The type of the elements in the matrices.</typeparam>
    public interface IMatrixArithmeticHelper<T>
    {
        /// <summary>
        /// Provides an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object
        /// as result value of adding two specified matrices.
        /// </summary>
        /// <param name="left">The left matrix operand.</param>
        /// <param name="right">The right matrix operand.</param>
        /// <param name="op">The <see cref="T:Academy.Numerics.IArithmeticOperator`1"/> used to add matrix elements.</param>
        /// <returns>
        /// an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object that contains the result values 
        /// of add the two specified <see cref="T:Academy.Collections.Generic.IMatrix`1"/> objects.
        /// </returns>
        IMatrix<T> Add(IMatrix<T> left, IMatrix<T> right, IArithmeticOperator op);
        /// <summary>
        /// Provides an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object
        /// as result value of subtract two specified matrices.
        /// </summary>
        /// <param name="left">The left matrix operand.</param>
        /// <param name="right">The right matrix operand.</param>
        /// <param name="op">The <see cref="T:Academy.Numerics.IArithmeticOperator`1"/> used to Subtract matrix elements.</param>
        /// <returns>
        /// an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object that contains the result values 
        /// of Subtract the two specified <see cref="T:Academy.Collections.Generic.IMatrix`1"/> objects.
        /// </returns>
        IMatrix<T> Subtract(IMatrix<T> left, IMatrix<T> right, IArithmeticOperator op);
        /// <summary>
        /// Provides an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object
        /// as result value of multiply two specified matrices.
        /// </summary>
        /// <param name="left">The left matrix operand.</param>
        /// <param name="right">The right matrix operand.</param>
        /// <param name="op">The <see cref="T:Academy.Numerics.IArithmeticOperator`1"/> used to multiply matrix elements.</param>
        /// <returns>
        /// an <see cref="T:Academy.Collections.Generic.IMatrix`1"/> object that contains the result values 
        /// of multiply the two specified <see cref="T:Academy.Collections.Generic.IMatrix`1"/> objects.
        /// </returns>
        IMatrix<T> Multiply(IMatrix<T> left, IMatrix<T> right, IArithmeticOperator op);
    }
}
